package com.uni.common.util;

import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
import java.util.concurrent.ScheduledExecutorService;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;


/**
 * 
 * @author yanzheng_Yu
 *
 */
@Component
public class SystemConfig {

//	public static String filePath = "E:\\mnt\\mfs";

	public static String filePath = "/mnt/guarantee/mfs";


	
//	public static String basePath = "https://www.yingmuren.com/gf";
public static String basePath = "http://106.13.225.125:90";
//	public static String baseUrl = "https://www.yingmuren.com";
public static String baseUrl = "http://106.13.225.125:90";
	public static String projectName = "";
	
	public static ExecutorService threadPool = Executors.newFixedThreadPool(5);
	
	//计划任务
	public static ScheduledExecutorService schedulePool = Executors.newScheduledThreadPool(5);
	
	
	@Value("${uni.filePath}")
	public void setFilePath(String filePath) {
		SystemConfig.filePath = filePath;
	}

	@Value("${uni.basePath}")
	public void setBasePath(String basePath) {
		System.out.println(basePath);
		SystemConfig.basePath = basePath;
	}

	@Value("${uni.baseUrl}")
	public void setBaseUrl(String baseUrl) {
		SystemConfig.baseUrl = baseUrl;
	}
	
	@Value("${uni.projectName}")
	public void setProjectName(String projectName) {
		SystemConfig.projectName = projectName;
	}
}
